package view.nn.com.myapplication;

import android.os.Bundle;
import android.view.View;
import android.widget.LinearLayout;

import com.joanzapata.pdfview.PDFView;
import com.joanzapata.pdfview.listener.OnPageChangeListener;

/**
 */
public class ContactActivity extends BaseActivity implements OnPageChangeListener {

    private PDFView pdf;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.contact_layout);
        LinearLayout parent = (LinearLayout) findViewById(R.id.parentAdview);
        //set adview
        showHP(parent);
        //set interstitial
        showCP();
        //set pdf view
        String page = "contact.pdf";
        pdf = (PDFView) findViewById(R.id.pdfView);
        pdf.fromAsset(page)
                .defaultPage(1)
                .showMinimap(false)
                .enableSwipe(true)
                .onPageChange(this)
                .load();
    }

    @Override
    public void onPageChanged(int page, int pageCount) {

    }

    public void onClick(View view) {
        finish();
    }
}